home *** CD-ROM | disk | FTP | other *** search
/ Graphics & Sound Program…ng Techniques for the Mac / Graphics and Sound Programming Techniques for the Mac.iso / Goodies / Animation Libraries / GENetRelease2ƒ / LibHeaders / FastBitCopies.h < prev    next >
Encoding:
Text File  |  1994-06-23  |  1.4 KB  |  66 lines  |  [TEXT/MPS ]

  1. /*
  2.     FastBitCopies.h
  3.     
  4.     Interface to FastBitCopies.c
  5.     
  6.     Special bit copy routines for 8-bit graphics
  7.     
  8.     Copyright 1993 by Al Evans
  9.     
  10.     1/27/93
  11.     
  12. */
  13.  
  14. //Defined for shareware and commercial releases
  15. #undef COMMERCIAL_RELEASE
  16.  
  17. //For internal use only
  18. #undef TESTING_C_RTNS
  19.  
  20. //Is this for the PowerMac?
  21. #if (defined(powerc) || defined(__powerc) || defined (TESTING_C_RTNS))
  22. #define MoveBitsXP CMoveBitsXP
  23. #define MoveBitsCP CMoveBitsCP
  24. #define MoveBitsMasked CMoveBitsMasked
  25. #endif
  26.  
  27. enum {
  28.     notTransparent = 40
  29. };
  30.  
  31. #ifdef __cplusplus
  32. extern "C" {
  33. #endif
  34.  
  35. pascal void FastCopyBits(const BitMap *srcBits,const BitMap *dstBits,const Rect *srcRect,
  36.     const Rect *dstRect,short mode,RgnHandle maskRgn);
  37.  
  38. #ifdef COMMERCIAL_RELEASE
  39. //Returns a ptr to a 8-bit mask the same size  as srcBits
  40. //The mask contains 0xFF for each zero byte in srcBits, 0x00 for all others
  41. Ptr    MakeMask(const BitMap *srcBits);
  42. #endif
  43.  
  44. /*
  45.     Assembly engines
  46. */
  47.  
  48. extern void MoveBitsXP(Ptr source, Ptr dest, 
  49.                     long nLines, long nBytesPerLine,
  50.                     long srcRowBytes, long destRowBytes, long mirrorFlags);
  51.                     
  52.  
  53. extern void MoveBitsCP(Ptr source, Ptr dest, 
  54.                     long nLines, long nBytesPerLine,
  55.                     long srcRowBytes, long destRowBytes);
  56.                     
  57. #ifdef COMMERCIAL_RELEASE
  58. extern void MoveBitsMasked(Ptr source, Ptr dest, 
  59.                     long nLines, long nBytesPerLine,
  60.                     long srcRowBytes, long destRowBytes, Ptr mask, long mirrorFlags);
  61. #endif
  62.                     
  63. #ifdef __cplusplus
  64. }
  65. #endif
  66.